package com.ch.domain;

/**
 * @author chenhong
 * @version 1.0.0
 * @ClassName Student.java
 * @Description TODO
 * @createTime 2020年12月21日 20:44:00
 */
public class Student extends Person{
    private Integer id;

    public Student(String name, Character sex, Integer id) {
        super(name, sex);
        this.id = id;
    }

    public Student() {
    }
    private void fun(){
        System.out.println("一个私有方法");
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    @Override
    public String toString() {
        return "Student{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", sex=" + sex +
                '}';
    }
}
